#include "internalhtml.h"

InternalHTML::InternalHTML(std::string title, std::string text)
{
    this->title = title;
    this->text = text;
}

void InternalHTML::addText(std::string text)
{
    this->text += text;
}

void InternalHTML::setTitle(std::string title)
{
    this->title = title;
}

void InternalHTML::clearText()
{
    this->text = "";
}

std::string InternalHTML::constructHTML()
{
    std::stringstream html;
    html << "<html><head><title>" << title << "</title></head><body>" << text << "</body></html>";
    return html.str();
}
